<?php
namespace App\Models;

use Illuminate\Database\Eloquent\Model;

class ActivityGather extends Model
{
    protected $table = 'activity_gather';//活动表
    public $timestamps = false;
    protected $guarded = [
    ];

    public function gather_first(){
        return \DB::table($this->table)->select('id','content')->first();
    }

    //添加活动合集
    public function gather_add($data){
        $arr = array(
            'content' => $data['content'],
            'created_at' => date('Y-m-d H:i:s',time()),
        );
        return \DB::table($this->table)->where('id',$data['id'])->update($arr);
    }


}